import request from '@/utils/request'

// 查询用户积分变动列表
export function listUserPoints(query) {
  return request({
    url: '/course/userPoints/list',
    method: 'get',
    params: query
  })
}

// 查询用户积分变动详细
export function getUserPoints(id) {
  return request({
    url: '/course/userPoints/' + id,
    method: 'get'
  })
}

// 新增用户积分变动
export function addUserPoints(data) {
  return request({
    url: '/course/userPoints',
    method: 'post',
    data: data
  })
}

// 修改用户积分变动
export function updateUserPoints(data) {
  return request({
    url: '/course/userPoints',
    method: 'put',
    data: data
  })
}

// 删除用户积分变动
export function delUserPoints(id) {
  return request({
    url: '/course/userPoints/' + id,
    method: 'delete'
  })
}
